//
//  MyOrderOtherFunction.m
//  X-Touch2
//
//  Created by shengchao yang on 12-4-7.
//  Copyright (c) 2012年 foxhis. All rights reserved.
//

#import "MyOrderOtherFunction.h"
#import "MessageBoxBaseView.h"
#import "MyOrderMenuManagement.h"
#import "FileManager.h"
#import "Singleton.h"
#import "Common.h"

@implementation MyOrderOtherFunction

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
        [((UIButton *)[self.view viewWithTag:TagOfUIButton]) setTitle:TranslateStr(@"选择桌号") forState:UIControlStateNormal];
    }
    return self;
}
- (IBAction)buttonClicked:(id)sender{
    if (AppSession.isAnimating) {
        MyNSLog(@"上一个动画还未完成...");
        return;
    }
    [AppSession playMusic:VoiceFile(@"clicked.caf")];
    NSInteger bid = [sender tag];
    if (bid == TagOfUIButton) {
        MyNSLog(@"开台");
        NSDictionary *infos = [NSDictionary dictionaryWithObjectsAndKeys:@"login", @"obj",nil];
        postNWithInfos(@"SysMsg_RootView_PopOutMyOrderMenuManagement", nil, infos);
    }
}
- (void)viewDidLoad
{
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
}

- (void)viewDidUnload
{
    [super viewDidUnload];
    // Release any retained subviews of the main view.
    // e.g. self.myOutlet = nil;
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
	return YES;
}

@end
